diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index f63c2ddced3c..8e8add8c6ed3 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -370,7 +370,10 @@ bool stmmac_eee_init(struct stmmac_priv *priv)

 	if ((interface != PHY_INTERFACE_MODE_MII) &&
 	    (interface != PHY_INTERFACE_MODE_GMII) &&
-	    !phy_interface_mode_is_rgmii(interface))
+		(interface != PHY_INTERFACE_MODE_RGMII) &&
+		(interface != PHY_INTERFACE_MODE_RGMII_ID) &&
+		(interface != PHY_INTERFACE_MODE_RGMII_TXID) &&
+		(interface != PHY_INTERFACE_MODE_RGMII_RXID))
 		goto out;

 	/* Using PCS we cannot dial with the phy registers at this stage
